package cn.iocoder.yudao.module.pickbook.controller.admin.userreadinghistory.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import com.alibaba.excel.annotation.*;
import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
import cn.iocoder.yudao.framework.excel.core.convert.DictConvert;

@Schema(description = "管理后台 - 用户阅读记录 Response VO")
@Data
@ExcelIgnoreUnannotated
public class UserReadingHistoryRespVO {

    @Schema(description = "记录唯一ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "11717")
    @ExcelProperty("记录唯一ID")
    private Long id;

    @Schema(description = "用户ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "3787")
    @ExcelProperty("用户ID")
    private Long userId;

    @Schema(description = "书籍ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "31848")
    @ExcelProperty("书籍ID")
    private Long bookId;

    @Schema(description = "是否已读完", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty(value = "是否已读完", converter = DictConvert.class)
    @DictFormat("infra_boolean_string") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private Integer isCompleted;

    @Schema(description = "上次阅读页码", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("上次阅读页码")
    private Integer lastPage;

    @Schema(description = "总阅读时间（分钟）", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("总阅读时间（分钟）")
    private Integer totalTime;

    @Schema(description = "阅读次数", requiredMode = Schema.RequiredMode.REQUIRED, example = "9194")
    @ExcelProperty("阅读次数")
    private Integer readCount;

    @Schema(description = "创建时间")
    @ExcelProperty("创建时间")
    private LocalDateTime createTime;

}